<?php

/**
 * @author lioxca
 * @copyright 2012
 */

    include_once($_SERVER['DOCUMENT_ROOT'].'/LLKH/Models/NguoiDung.php');
    
    class LoaiTinHoc extends NguoiDung{
        private $LTH_Ma;
        private $LTH_Ten;
                        
        public function setLTHMa($LTH_Ma){
            $this->LTH_Ma = $LTH_Ma;
        }
        public function getLTHMa(){
            return $this->LTH_Ma;
        }
        public function setLTHTen($LTH_Ten){
            $this->LTH_Ten = $LTH_Ten;
        }
        public function getLTHTen(){
            return $this->LTH_Ten;
        }        
        
                
        public function suaLTH(){
            $query = "update LoaiTinHoc set LTH_Ten='".$this->getLTHTen()."' where LTH_Ma='".$this->getLTHMa()."'";
             //echo $this->getQuery();
            $this->setQuery($query);
            return $this->executeQuery();
        }
        
        public function dsLTH(){
            $this->setQuery("select * from LoaiTinHoc");
            return $this->fetchAll();
        }
    }

?>

